#pragma once

#include <Afxinet.h>

class CMyInternetSession :
	public CInternetSession
{
public:
	CMyInternetSession(void);
	~CMyInternetSession(void);

	CMyInternetSession(LPCTSTR pszAppName,
					   int nMethod, 
					   LPCTSTR pstrProxyName, 
					   LPCTSTR pstrProxyBypass, 
					   DWORD dwFlags);

	virtual void OnStatusCallback(DWORD dwContext, 
								  DWORD dwInternetStatus,
								  LPVOID lpvStatusInformation, 
								  DWORD dwStatusInformationLength);

	DWORD GetWebFile(LPCTSTR pszAppName, 
					 LPCTSTR lpstrServer,
					 int nPort, 
					 CString lpstrFile);

	void ShowStatus(LPCTSTR strStatus);

	DWORD AutologinIn();
};
